import socket
s = socket.socket(socket.AF_INET,socket.SOCK_STREAM)
port = 65523 
s.bind(("",port))
s.listen(5)
con,addr = s.accept()
print "connect from ",addr
con.send('test')
print con.recv(1024)
con.close()
